<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>微仓出入仓记录</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<link href="admin.css" rel="stylesheet" type="text/css" />
<link href="cxcalendar.css" rel="stylesheet" type="text/css" />
<script type="text/javascript" src="../script/jquery-1.4.4.min.js"></script>
<script language="javascript" src="../script/Calendar-new.js"></script>
<script type="text/javascript">
$(function(){
	//时间搜索
	$('.input_cxcalendar').each(function(){
	    var a = new Calendar({
	        targetCls: $(this),
	        type: 'yyyy-mm-dd HH:MM:SS',
	        wday:2
	    },function(val){
	        console.log(val);
	    });
	});
});
</script>
</head>
<body>
<div class="container">
    <div class="flow">
        <div class="itemtitle">
            <h3>出入仓记录</h3>
            <ul>
                <li><a href="?m=<{$smarty.get.m}>&s=micro_stock_shop.php"><span>微仓列表</span></a></li>
                <li class="current"><a href="javascript:;"><span>明细</span></a></li>
            </ul>
        </div>
    </div>
    <div class="h35"></div>
    
    <form action="" method="get">
	    <input type="hidden" name="m" value="<{$smarty.get.m}>">
	    <input type="hidden" name="s" value="<{$smarty.get.s}>">
	    <input type="hidden" name="memberId" value="<{$smarty.get.memberId}>">
	    <table>
	        <tr>    
	            <td>
       				<span>仓库:&nbsp;&nbsp;&nbsp;</span>
       				<span>
	                    <select name="stock_shop" id="stock_shop">
		                <option value="">全部</option>
		                <{foreach item=list from=$de.numByShop}>
		                <option value="<{$list.stock_shop}>" <{if $smarty.get.stock_shop==$list.stock_shop}>selected<{/if}>><{$list.shop_name}>(<{$list.total}>)</option>
		                <{/foreach}>
		                </select>
	                </span>
	                <span>类型:&nbsp;&nbsp;&nbsp;</span>
       				<span>
	                    <select name="type" id="type">
		                	<option value="in">入仓</option>
		                	<option value="out" <{if $smarty.get.type=='out'}>selected<{/if}>>出仓</option>
		                </select>
	                </span>
	                <span>&nbsp;产品ID:&nbsp;&nbsp;&nbsp;</span>
	                <span><textarea name="product_id" style="resize:horizontal;height:18px;" placeholder="多个请用英文逗号隔开"><{$smarty.get.product_id}></textarea></span>
	                <span>&nbsp;入/出 仓时间：</span>
                    <span>
                            <input class="w120 input_cxcalendar" type="text" name="stime" id="stime" value="<{$smarty.get.stime}>"">
                            -
                            <input class="w120 input_cxcalendar" type="text" name="etime" id="etime" value="<{$smarty.get.etime}>"">
                    </span>
	            </td>
	            <td>
                	<span>&nbsp;&nbsp;&nbsp;<input type="submit" value="搜索" /></span>
            	</td>
	        </tr>
	    </table>
    </form>
    
    <table class="table product">
       <tbody>
       <tr class="header">
            <th width="100">仓库</th>
            <th width="100">订单ID</th>
            <th width="100">产品ID</th>
            <th width="100">产品图片</th>
            <th width="100">产品名称</th>
            <th width="100">规格</th>
            <th width="100">入仓/出仓</th>
            <th width="100">价格</th>
            <th width="100">数量</th>
            <th width="100">sku总(出/入)数量</th>
            <th width="100">时间</th>
        </tr>
        <{foreach item=list key=key from=$de.list}>
        <tr>
            <td><{$list.shop_name}></td>
            <td><{$list.order_id}></td>
            <td><{$list.pid}></td>
            <td><a href="<{$list.pic}>" target="_blank"><img width="80" src="<{$list.pic}>/80"></a></td>
            <td><{$list.product_name}></td>
            <td><{$list.property}></td>
            <td><{if $smarty.get.type=='out'}>出仓<{else}>入仓<{/if}></td>
            <td><{if $smarty.get.type=='out'}>---<{else}><{$list.price}><{/if}></td>
            <td><{$list.num}></td>
            <td><{$list.total_num}></td>
            <td><{$list.create_time}></td>
        </tr>
        <{foreachelse}>
        <tr>
            <td class="norecord" colspan="99"><i></i><span>暂无符合条件的数据记录</span></td>
        </tr>
        <{/foreach}>
		</tbody>
        <tfoot>
            <tr>
                <td colspan="99">
                	<div class="fl">每页最多显示： <{$de.perPageRows}>条</div>
                    <div class="page"><{$de.page}></div>
                    <div class="fr">共有<{$de.count}>条记录</div>
                </td>
            </tr>
        </tfoot>
    </table>
</div>
</body>
</html>